﻿using DocumentFormat.OpenXml.Lite.Xml;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Schema;
using System.Xml.Serialization;

namespace DocumentFormat.OpenXml.Lite.WordprocessingML.Shared
{
    public class NullableValue<T> : XmlSerializable
    {
        [Optional]
        [XmlAttribute("val", Namespace = Constants.WordMain, Form = XmlSchemaForm.Qualified)]
        public T Value { get; set; }

        public NullableValue() { }

        public NullableValue(T val) 
        {
            Value = val;
        }
    }
}
